package com.vita.core.task;

public interface Task{
    /**
     * 单步骤任务
     */
    void plan(TaskExecute execute);

    /**
     * 多步骤任务
     */
    default Task oneStep(Task task){return null;}

    public static void main(String[] args) {
        new Task(){
            @Override
            public void plan(TaskExecute execute) {

            }
        }.plan(new TaskExecute() {
            @Override
            public void run(String s) {

            }
        });
    }
}
